<?php

class Api{
    function post($req){
        $path = $_FILES['file']['tmp_name'];
        $data = file_get_contents($path);
        $url = pt\AliyunOss::init()->uploadContent(md5(rand(10000,22222).time().time()).".png",$data,false);
        return array(
            "url"=>$url
        );
    }
}
